import request from '@/utils/request'

/* 员工列表分页*/
export function selectEmployeePage(data) {
  return request({
    url: '/erp/employee/selectEmployeePage',
    method: 'post',
    data: data
  })
}

/* 新增员工*/
export function saveEmployee(data) {
  return request({
    url: '/erp/employee/saveEmployee',
    method: 'post',
    data: data
  })
}

/* 修改员工*/
export function updateEmployee(data) {
  return request({
    url: '/erp/employee/updateEmployeeById',
    method: 'post',
    data: data
  })
}

/* 删除员工*/
export function deleteEmployee(data) {
  return request({
    url: '/erp/employee/deleteEmployee',
    method: 'post',
    data: data
  })
}

/* 根据员工名称查询*/
export function selectEmployeeByName(data) {
  return request({
    url: '/erp/employee/selectEmployeeByName',
    method: 'post',
    data: data
  })
}

/* 根据id查询*/
export function selectEmployeeById(data) {
  return request({
    url: '/erp/employee/selectEmployeeById/' + data,
    method: 'post'
  })
}

/* 根据班次id查询已分配员工 */
export function selectDistributedEmployee(data) {
  return request({
    url: '/erp/employee/selectDistributedEmployee/' + data,
    method: 'post'
  })
}

/* 根据班次id查询未分配员工 */
export function selectUndistributedEmployee(data) {
  return request({
    url: '/erp/employee/selectUndistributedEmployee',
    method: 'post',
    data: data
  })
}
